#科技平台 自动
import requests
url = 'http://localhost/dev-api/login'
payload = {
    "username":"880390",
    "password":"0"
}

headers = {
    "Accept": "image/gif, image/jpeg, image/pjpeg, application/x-ms-application, application/xaml+xml, application/x-ms-xbap, */*",
    "Accept-Encoding": "gzip, deflate",
    "Accept-Language": "zh-Hans-CN,zh-Hans;q=0.8,en-US;q=0.5,en;q=0.3",
    "Host": "127.0.0.1",
    "User-Agent": "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; Tablet PC 2.0; wbx 1.0.0; wbxapp 1.0.0; Zoom 3.6.0)",
    "X-Amzn-Trace-Id": "Root=1-628b672d-4d6de7f34d15a77960784504"
}
#print("headers:", headers)
login_res = requests.post(url,json=payload,headers=headers)
# 从响应结果中获取token值
token = login_res.json()["token"]
headers["Authorization"] = 'Bearer '+token;
print("headers:", headers);

list_url = 'http://localhost/dev-api/processInstance/myinpilist?pageNum=1&pageSize=10'
login_res = requests.post(list_url,json=payload,headers=headers)
print("login_res:", login_res);
